package(default_visibility = ["//visibility:public"])

licenses(["notice"])

cc_library(
    name = "util",
    srcs = ["util.cc"],
    hdrs = ["util.h"],
    deps = [
        "@tink_cc//:binary_keyset_reader",
        "@tink_cc//:binary_keyset_writer",
        "@tink_cc//:cleartext_keyset_handle",
        "@tink_cc//:keyset_handle",
        "@tink_cc//:keyset_reader",
        "@tink_cc//:keyset_writer",
        "@tink_cc//config:tink_config",
        "@tink_cc//util:status",
    ],
)

cc_binary(
    name = "digital_signatures_cli",
    srcs = ["digital_signatures_cli.cc"],
    deps = [
        ":util",
        "@tink_cc//:public_key_sign",
        "@tink_cc//:public_key_verify",
        "@tink_cc//signature:signature_key_templates",
    ],
)

sh_test(
    name = "digital_signatures_cli_test",
    size = "small",
    srcs = ["digital_signatures_cli_test.sh"],
    args = [
        "$(rootpath :digital_signatures_cli)",
    ],
    data = [":digital_signatures_cli"],
)
